package adv7;

public class DownloadThread extends Thread {
	public DownloadThread(String n) {
		super(n);
	}

	@Override
	public void run() {
		// 模拟多线程下载
		for (int i = 1; i <= 20; i++) {
			System.out.printf(super.getName() + "下载了%dM字节\n", i);
			super.yield();
		}
	}
}
